package com.lanou3g.demo.base.service;

import com.lanou3g.demo.entity.Account;
import com.lanou3g.demo.entity.ExAccount;
import com.lanou3g.demo.mapper.AccountMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
import java.util.Map;

@Service
public class AccountService implements IAccountService {
    @Autowired
    private AccountMapper account;


    @Override
    public List<ExAccount> findAllAccount(ExAccount a) {
        return account.findAllAccount(a);
    }

    @Override
    public List<Account> findByPage(Integer page) {
        return account.findByPage(page);
    }

    @Override
    public int modifyStatus(Account a) {
        return account.modifyStatus(a);
    }

    @Override
    public ExAccount findDetail(Integer accountId) {
        return account.findDetail(accountId);
    }

    @Override
    public ExAccount findRecommenderIdCard(ExAccount exAccount) {
        return account.findRecommenderIdCard(exAccount);
    }

    @Override
    public int addAccount(Account a) {
        return account.addAccount(a);
    }

    @Override
    public List<ExAccount> findByTerm(ExAccount a) {
        return account.findByTerm(a);
    }

    @Override
    public Map<String, Integer> findByIdcardNo(String idcardNo) {
        return account.findByIdcardNo(idcardNo);
    }

    @Override
    public int modifyInfo(Account a) {
        return account.modifyInfo(a);
    }

    @Override
    public int modifyServiceStatus(Account a) {
        return account.modifyServiceStatus(a);
    }


}
